-
Notifications
You must be signed in to change notification settings - Fork 961
Use events API to eager send attestations #7892
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: unstable
Are you sure you want to change the base?
Conversation
|
Some required checks have failed. Could you please take a look @hopinheimer? 🙏 |
| let mut last_slot = self.latest_attested_slot.lock().await; | ||
|
|
||
| if current_slot <= *last_slot { | ||
| debug!(?current_slot, "Attestation already initiated for the slot"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This log is a bit noisy, it's happening even on my VC with only a single validator, and at slots my validator is not even attesting.
I think the flow is:
- Head event arrives
- Trigger attestation service
- Nothing to do (not an attester), update latest slot
- Go round the loop again
- Still the same slot, so wait for slot + 1/3
- 1/3 of slot arrives, we've already set
last_slot-> log message
Maybe we should add a sleep at the end of this loop until the next slot so that we don't wrap round like this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe the sleep should be until the start of the original slot + 1 actually, just in case the attestation process takes a long time. We don't want "next slot" to actually be slot + 2 by the time this calculation is done
addresses #7820
I haven't done benches for the change in kurtosis but post results soon